package com.example.demo111111.dao;

import com.example.demo111111.entity.Product;
import com.github.pagehelper.Page;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;

@Mapper
public interface ProductDao {
    Boolean save(Product product);

    Boolean update(Product product);

    Page<Product> pageQuery(Product product);

    @Delete("delete  from product where id=#{id}")
    Boolean deleteById(Long id);


    @Delete("delete  from product where merchant_id=#{id}")
    void deleteByMerchantId(Long id);
}
